% test
x = [   -0.5295
    0.2821
   0.6505
    0.0059];
pos = jpos_mat(x);
legs = plot([0 0], 'k');
set(legs, 'XData', pos(1,:), 'YData', pos(2,:), ...
            'erasemode', 'normal');